Page({

  /**
   * 页面的初始数据
   */
  data: {
    schema: [],
    formData: {},
    title: '',
    result: '',
    remark: '',
    webUrl: ''
  },
  onLoad(options) {
    console.log('options', options)
    wx.setNavigationBarTitle({
      title: options.title,
    })

    this.setData({
      title: options.title,
      zh:options.zh,
      remark: options.remark,
      webUrl: options.webUrl
    })
  },
  getFormData(e) {
    this.setData({
      formData: e.detail.formData
    })
  },
  choose1() {
    const query = wx.createSelectorQuery()
    query.select('#the-id').boundingClientRect((t) => {
      wx.showModal({
        title: '执行了boundingClientRect方法的回调',
        showCancel: false
      })
    }).exec((r) => {
      this.setData({
        result: r
      })
    })
  },
  choose2() {
    const query = wx.createSelectorQuery()
    query.select('#the-id2').boundingClientRect((t) => {
      wx.showModal({
        title: '执行了boundingClientRect方法的回调',
        showCancel: false
      })
    }).exec((r) => {
      this.setData({
        result: r
      })
    })
  },
  choose3() {
    const query = wx.createSelectorQuery()
    query.selectAll('.the-id').boundingClientRect((t) => {
      wx.showModal({
        title: '执行了boundingClientRect方法的回调',
        showCancel: false
      })
    }).exec((r) => {
      this.setData({
        result: r
      })
    })
  },
  choose4() {
    const query = wx.createSelectorQuery()
    query.selectAll('.the-id2').boundingClientRect((t) => {
      wx.showModal({
        title: '执行了boundingClientRect方法的回调',
        showCancel: false
      })
    }).exec((r) => {
      this.setData({
        result: r
      })
    })
  },
  choose5() {
    const query = wx.createSelectorQuery()
    query.selectViewport().boundingClientRect((t) => {
      wx.showModal({
        title: '执行了boundingClientRect方法的回调',
        showCancel: false
      })
    }).exec((r) => {
      this.setData({
        result: r
      })
    })
  },
})